package com.itmk;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

import java.io.IOException;

@SpringBootApplication
public class BooksApplication implements CommandLineRunner {
    public static void main(String[] args) {
        SpringApplication.run(BooksApplication.class,args);
    }


    @Override
    public void run(String... args) throws Exception {

        String frontUrl = "http://localhost:8089/#/login?redirect=%2Fdashboard";
        try {
            Runtime.getRuntime().exec(
                    "cmd   /c   start  "+frontUrl);
        } catch (IOException e) {

            e.printStackTrace();
        }


    }
}
